- cccchhhhaaaarrrr ****yyyyyyyytttteeeexxxxtttt holds the text of the current token. It
may be modified but not lengthened (you cannot append
characters to the end). Modifying the last character
may affect the activity of rules anchored using '^'
during the next scan; see fffflllleeeexxxxddddoooocccc((((1111)))) for details.
If the special directive %%%%aaaarrrrrrrraaaayyyy appears in the first
section of the scanner description, then yyyyyyyytttteeeexxxxtttt is
instead declared cccchhhhaaaarrrr yyyyyyyytttteeeexxxxtttt[[[[YYYYYYYYLLLLMMMMAAAAXXXX]]]],,,, where YYYYYYYYLLLLMMMMAAAAXXXX is a
macro definition that you can redefine in the first
section if you don't like the default value (generally
8KB). Using %%%%aaaarrrrrrrraaaayyyy results in somewhat slower
scanners, but the value of yyyyyyyytttteeeexxxxtttt becomes immune to
calls to _i_n_p_u_t() and _u_n_p_u_t(), which potentially destroy
its value when yyyyyyyytttteeeexxxxtttt is a character pointer. The
opposite of %%%%aaaarrrrrrrraaaayyyy is %%%%ppppooooiiiinnnntttteeeerrrr,,,, which is the default.
You cannot use %%%%aaaarrrrrrrraaaayyyy when generating C++ scanner
classes (the ----++++ flag).
- iiiinnnntttt yyyyyyyylllleeeennnngggg holds the length of the current token.
- FFFFIIIILLLLEEEE ****yyyyyyyyiiiinnnn is the file which by default _f_l_e_x reads
from. It may be redefined but doing so only makes
sense before scanning begins or after an EOF has been
Version 2.4 Last change: November 1993 8
FLEX(1) User Commands FLEX(1)
encountered. Changing it in the midst of scanning will
have unexpected results since _f_l_e_x buffers its input;
use yyyyyyyyrrrreeeessssttttaaaarrrrtttt(((()))) instead. Once scanning terminates
because an end-of-file has been seen, yyyyoooouuuu ccccaaaannnn aaaassssssssiiiiggggnnnn
_y_y_i_n at the new input file and then call the scanner
again to continue scanning.
- vvvvooooiiiidddd yyyyyyyyrrrreeeessssttttaaaarrrrtttt(((( FFFFIIIILLLLEEEE ****nnnneeeewwww____ffffiiiilllleeee )))) may be called to point
_y_y_i_n at the new input file. The switch-over to the new
file is immediate (any previously buffered-up input is
lost). Note that calling yyyyyyyyrrrreeeessssttttaaaarrrrtttt(((()))) with _y_y_i_n as an
argument thus throws away the current input buffer and
continues scanning the same input file.
- FFFFIIIILLLLEEEE ****yyyyyyyyoooouuuutttt is the file to which EEEECCCCHHHHOOOO actions are done.
It can be reassigned by the user.
- YYYYYYYY____CCCCUUUURRRRRRRREEEENNNNTTTT____BBBBUUUUFFFFFFFFEEEERRRR returns a YYYYYYYY____BBBBUUUUFFFFFFFFEEEERRRR____SSSSTTTTAAAATTTTEEEE handle to
the current buffer.
- YYYYYYYY____SSSSTTTTAAAARRRRTTTT returns an integer value corresponding to the
current start condition. You can subsequently use this
value with BBBBEEEEGGGGIIIINNNN to return to that start condition.